<?php

namespace Sifast\ProjectBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * Permis
 *
 * @ORM\Table()
 * @ORM\Entity(repositoryClass="Sifast\ProjectBundle\Entity\PermisRepository")
 */
class Permis {

    /**
     * @var integer
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * @var string
     *
     * @ORM\Column(name="type_permis", type="string", length=255)
     */
    private $typePermis;

    /**
     * @var string
     *
     * @ORM\Column(name="date_obtention", type="string", length=255)
     */
    private $dateObtention;

    /**
     * @var string
     *
     * @ORM\Column(name="date_expiration", type="string", length=255)
     */
    private $dateExpiration;

    /**
     * @var integer
     *
     * @ORM\Column(name="num_permis", type="integer")
     */
    private $numPermis;

    /**
     * @var integer
     *
     * @ORM\ManyToOne(targetEntity="Application\Sonata\UserBundle\Entity\User", inversedBy="permis", cascade={"remove", "persist"})

     */
    private $user;

    /**
     * Get id
     *
     * @return integer 
     */
    public function getId() {
        return $this->id;
    }

    /**
     * Set typePermis
     *
     * @param string $typePermis
     * @return Permis
     */
    public function setTypePermis($typePermis) {
        $this->typePermis = $typePermis;

        return $this;
    }

    /**
     * Get typePermis
     *
     * @return string 
     */
    public function getTypePermis() {
        return $this->typePermis;
    }

    /**
     * Set dateExpiration
     *
     * @param string $dateExpiration
     * @return Permis
     */
    public function setDateExpiration($dateExpiration) {
        $this->dateExpiration = $dateExpiration;

        return $this;
    }

    /**
     * Get dateExpiration
     *
     * @return string 
     */
    public function getDateExpiration() {
        return $this->dateExpiration;
    }

    /**
     * Set numPermis
     *
     * @param integer $numPermis
     * @return Permis
     */
    public function setNumPermis($numPermis) {
        $this->numPermis = $numPermis;

        return $this;
    }

    /**
     * Get numPermis
     *
     * @return integer 
     */
    public function getNumPermis() {
        return $this->numPermis;
    }

    /**
     * Set dateObtention
     *
     * @param string $dateObtention
     * @return Permis
     */
    public function setDateObtention($dateObtention) {
        $this->dateObtention = $dateObtention;

        return $this;
    }

    /**
     * Get dateObtention
     *
     * @return string 
     */
    public function getDateObtention() {
        return $this->dateObtention;
    }


    /**
     * Set user
     *
     * @param \Application\Sonata\UserBundle\Entity\User $user
     * @return Permis
     */
    public function setUser(\Application\Sonata\UserBundle\Entity\User $user = null)
    {
        $this->user = $user;
    
        return $this;
    }

    /**
     * Get user
     *
     * @return \Application\Sonata\UserBundle\Entity\User 
     */
    public function getUser()
    {
        return $this->user;
    }
}